package util;

import java.util.ArrayList;
import java.util.List;

import util.PhysicalFeature;
import util.PhysicalFeature.*;

public class PhysicalFeatureUtil {

	public static List<Gender> getGenders(){
		List<Gender> genders=new ArrayList<Gender>();
		genders.add(new Gender("female","Female"));
		genders.add(new Gender("male","Male" ));

		return genders;
	}
	public static Gender getGenderByGenderName(String genderName){
		List<Gender> genders=getGenders();
		for(Gender gender: genders){
			if(gender.getGenderName().equalsIgnoreCase(genderName))
				return gender;
		}
		return null;
	}
	
	
	public static List<Hair> getHairs(){
		List<Hair> hairs=new ArrayList<Hair>();
		hairs.add(new Hair("blond","Blond"));
		hairs.add(new Hair("red","Red" ));
		hairs.add(new Hair("brown","Brown"));
		hairs.add(new Hair("gray","Gray" ));
		hairs.add(new Hair("auburn","Auburn"));
		hairs.add(new Hair("black","Black" ));
		hairs.add(new Hair("chestnut","Chestnut"));
		hairs.add(new Hair("white","White" ));

		return hairs;
	}
	public static Hair getHairByHairName(String hairName){
		List<Hair> hairs=getHairs();
		for(Hair hair: hairs){
			if(hair.getHairName().equalsIgnoreCase(hairName))
				return hair;
		}
		return null;
	}
	
	
	public static List<Skin> getSkins(){
		List<Skin> Skins=new ArrayList<Skin>();
		Skins.add(new Skin("white","White"));
		Skins.add(new Skin("light","Light" ));
		Skins.add(new Skin("brown","Brown"));
		Skins.add(new Skin("black","Black" ));

		return Skins;
	}
	public static Skin getSkinBySkinName(String skinName){
		List<Skin> skins=getSkins();
		for(Skin skin: skins){
			if(skin.getSkinName().equalsIgnoreCase(skinName))
				return skin;
		}
		return null;
	}
	
	public static List<Eyes> getEyes(){
		List<Eyes> eyes=new ArrayList<Eyes>();
		eyes.add(new Eyes("blue","Blue"));
		eyes.add(new Eyes("green","Green" ));
		eyes.add(new Eyes("brown","Brown"));
		eyes.add(new Eyes("amber","Amber" ));
		eyes.add(new Eyes("gray","Gray"));
		eyes.add(new Eyes("hazel","Hazel" ));
		eyes.add(new Eyes("violet","Violet"));
		eyes.add(new Eyes("black","Black" ));

		return eyes;
	}
	public static Eyes getEyesByEyesName(String eyesName){
		List<Eyes> skins=getEyes();
		for(Eyes eye: skins){
			if(eye.getEyesName().equalsIgnoreCase(eyesName)){
				System.out.println(eye.getEyesShowName() + ", " + eye.getEyesName());
				return eye;
			}
		}
		return null;
	}
}

